package DataModel.DesignRulesManager;

import DataModel.CommonLibrary.CommonDefs.Layer;
import DataModel.DesignRulesManager.CCommonUtils.EDesignRuleType;

/**
 * Class representing single design rule
 * 
 * @author evgeni
 *
 */
public class CDesignRule 
{
	/***************************************************/
	/****** Members ************************************/
	/***************************************************/
	private String 			m_id;
	private EDesignRuleType m_type;
	private Layer			m_firstLayer;
	private Layer 			m_secondLayer;
	private double 			m_value;
	
	/***************************************************/
	/****** Getters / Setters ************************************/
	/***************************************************/
	public String getId() {
		return m_id;
	}
	public void setId(String id) {
		this.m_id = id;
	}
	public EDesignRuleType getType() {
		return m_type;
	}
	public void setType(EDesignRuleType type) {
		this.m_type = type;
	}
	public Layer getFirstLayer() {
		return m_firstLayer;
	}
	public void setFirstLayer(Layer layer) {
		m_firstLayer = layer;
	}
	public Layer getSecondLayer() {
		return m_secondLayer;
	}
	public void setSecondLayer(Layer layer) {
		m_secondLayer = layer;
	}
	public double getValue() {
		return m_value;
	}
	public void setValue(double value) {
		this.m_value = value;
	}
	
	/***************************************************/
	/****** Public methods ******************************/
	/***************************************************/
	public String toString()
	{
		return m_id + " " + m_type.toString() + " "  + m_firstLayer.toString() + " "  + 
		m_secondLayer.toString() + " "  + m_value;
	}
}
